var $;
function modify(){
    layui.use(['layer','jquery'], function(){
        $ = layui.jquery;
        var index = parent.layer.load(1, {
            shade: [0.3,'#000']
        });
        $.ajax({
            url:'/admin/interface/modify',
            datatype:'json',
            data:{
                "id":$('#code').val(),
                "uri":  $('#uri').val(),
                "memo":$('#memo').val()
            },
            success:function (res) {
                if(res.code == 0){
                    parent.layer.close(top.interfaceId);
                    parent.layer.msg(res.msg, {icon: 1});
                    top.interfaceTable.reload();
                }else{
                    parent.layer.msg(res.msg, {icon: 2});
                }
            },complete:function(res){
                parent.layer.close(index);
            }
        });
    });

}




